/****************************************************************************
**
** Copyright (C) 2021 The Qt Company Ltd.
** Contact: https://www.qt.io/licensing/
**
** This file is part of Qt Quick Studio Components.
**
** $QT_BEGIN_LICENSE:GPL$
** Commercial License Usage
** Licensees holding valid commercial Qt licenses may use this file in
** accordance with the commercial license agreement provided with the
** Software or, alternatively, in accordance with the terms contained in
** a written agreement between you and The Qt Company. For licensing terms
** and conditions see https://www.qt.io/terms-conditions. For further
** information use the contact form at https://www.qt.io/contact-us.
**
** GNU General Public License Usage
** Alternatively, this file may be used under the terms of the GNU
** General Public License version 3 or (at your option) any later version
** approved by the KDE Free Qt Foundation. The licenses are as published by
** the Free Software Foundation and appearing in the file LICENSE.GPL3
** included in the packaging of this file. Please review the following
** information to ensure the GNU General Public License requirements will
** be met: https://www.gnu.org/licenses/gpl-3.0.html.
**
** $QT_END_LICENSE$
**
****************************************************************************/

import QtQuick.Window 2.15
import QtQuick.Controls 2.15
import QtQuick
import QtQuick.Layouts

Window {
    width: 1048
    height: 600
    visible: true
    color: "#badbbb"
    title: "棋牌室"

    Rectangle {
        id: leftMenuView
        anchors.left: parent.left
        width: 300
        anchors.top: parent.top
        anchors.bottom: parent.bottom
        color: "#3d5276"

        ListView {
            id: leftListview
            anchors.fill: parent
            spacing: 2
            interactive: false
            model: ListModel {
                ListElement{title: "首页"; index: 0; iconUrl: "../asset_imports/icon/首页.png"}
                ListElement{title: "棋牌桌"; index: 1; iconUrl: "../asset_imports/icon/棋牌（场馆）.png"}
                ListElement{title: "零售商品"; index: 2; iconUrl: "../asset_imports/icon/收钱.png"}
                ListElement{title: "销售记录"; index: 3; iconUrl: "../asset_imports/icon/销售记录.png"}
                ListElement{title: "统计分析"; index: 4; iconUrl: "../asset_imports/icon/统计分析.png"}
            }
            delegate: ListMenuItemDelegate {}
        }

    }


    StackLayout {
        id: stackLayoutView
        anchors.top: parent.top
        anchors.right: parent.right
        anchors.left: leftMenuView.right
        anchors.bottom: parent.bottom
        currentIndex: 0

        Item {
            HomePage {
                id: homePage
            }
        }

        Item {
          CardPage{}
        }

        Item {
            GoodsPage {}
        }

        Item {
           SalesRecordPage{}
        }

        Item {
            //ChartsPage{}
        }
    }



    FontLoader{
            id: awe_loader
            source: "./fonts/Font Awesome 6 Free-Solid-900.otf"
    }

    FontLoader{
            id: segoe_loader
            source: "./fonts/Segoe_Fluent_Icons.ttf"
    }
}

